-- GENERATED SPELL FOR [Lord Aliden Perenolde] --


function spell0_2423(pUnit, Event) --@Power Word: Shield,n/a--
pUnit:FullCastSpellOnTarget(11974,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_2423', 30312, 1)
end

function spell1_2423(pUnit, Event) --@Renew,Heal--
pUnit:FullCastSpellOnTarget(8362,pUnit)
pUnit:RegisterEvent('Sorts_2423', 22000, 1)
end

function spell2_2423(pUnit, Event) --@Sleep,n/a--
pUnit:FullCastSpellOnTarget(15970,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_2423', 11000, 1)
end

function Sorts_2423(pUnit, Event)
local choix_sorts_2423 = math.random(0, 2)
if choix_sorts_2423 == 0 then
pUnit:RegisterEvent('spell0_2423', 1, 1)
end
if choix_sorts_2423 == 1 then
pUnit:RegisterEvent('spell1_2423', 1, 1)
end
if choix_sorts_2423 == 2 then
pUnit:RegisterEvent('spell2_2423', 1, 1)
end
end

function mob2423_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_2423', math.random(1500, 3000), 1)
end

function mob2423_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob2423_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob2423_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(2423, 1, 'mob2423_Action')
RegisterUnitEvent(2423, 2, 'mob2423_Leave')
RegisterUnitEvent(2423, 3, 'mob2423_Kill')
RegisterUnitEvent(2423, 4, 'mob2423_Die')
